from django.db import models

from user.models import UserProfile


# Create your models here.
class Column(models.Model):
    coid = models.BigAutoField(primary_key=True)
    name = models.CharField(max_length=50)
    description = models.TextField(blank=True)
    mup = models.ForeignKey(UserProfile, on_delete=models.CASCADE, related_name='column_mup')
    update_time = models.DateTimeField(auto_now=True)
    create_time = models.DateTimeField(auto_now_add=True)
    cover_path = models.CharField(max_length=200, default='https://bilimili2.oss-cn-beijing.aliyuncs.com/imgs/covers/default.png')
    status = models.BooleanField(default=True)

